package com.xbongbong.admin.feign;

import com.xbongbong.base.BaseIdListDTO;
import com.xbongbong.paas.toolbox.wrap.XbbResponse;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;


/**
 * 工单v2微服务相关调用
 * @author zheng.li
 */
@FeignClient(name = "xbb-work-order-web",contextId = "workOrderV2FeignClient")
public interface WorkOrderV2FeignClient {


    /**
     * 绑定表单至工单默认目录
     *
     * @param baseIdListDTO 入参
     * @param lang      语言
     * @return 返回数据
     */
    @RequestMapping(value = "/pro/v1/workOrderV2/catalog/formBindToDefault", method = RequestMethod.POST)
    String bindToDefault(@RequestBody BaseIdListDTO baseIdListDTO, @RequestParam("lang") String lang);

    /**
     * 绑定表单至工单默认目录
     *
     * @param baseIdListDTO 入参
     * @param lang      语言
     * @return 返回数据
     */
    @RequestMapping(value = "/pro/v1/workOrderV2/catalog/createDefaultProcess", method = RequestMethod.POST)
    String createDefaultProcess(@RequestBody BaseIdListDTO baseIdListDTO, @RequestParam("lang") String lang);

    /**
     * 镜像获取工单流程数据ID
     *
     * @param baseIdListDTO 入参
     * @param lang      语言
     * @return 返回数据
     */
    @RequestMapping(value = "/pro/v1/workOrderV2/catalog/getEnableProcess", method = RequestMethod.POST)
    String getEnableProcess(@RequestBody BaseIdListDTO baseIdListDTO, @RequestParam("lang") String lang);
}
